home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Personal Computer World 2009 February
/
PCWFEB09.iso
/
Software
/
Linux
/
Kubuntu 8.10
/
kubuntu-8.10-desktop-i386.iso
/
casper
/
filesystem.squashfs
/
usr
/
share
/
ufw
/
before6.rules
< prev
next >
Wrap
Text File
|
2008-10-08
|
2KB
|
57 lines
#
# rules.before
#
# Rules that should be run before the ufw command line added rules. Custom
# rules should be added to one of these chains:
# ufw6-before-input
# ufw6-before-output
# ufw6-before-forward
#
# Don't delete these required lines, otherwise there will be errors
*filter
:ufw6-before-input - [0:0]
:ufw6-before-output - [0:0]
:ufw6-before-forward - [0:0]
# End required lines
# allow all on loopback
-A ufw6-before-input -i lo -j ACCEPT
-A ufw6-before-output -o lo -j ACCEPT
# for stateless autoconfiguration
-A ufw6-before-input -p icmpv6 --icmpv6-type neighbor-solicitation -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type neighbor-advertisement -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type router-solicitation -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type router-advertisement -j ACCEPT
# connection tracking rules
-A ufw6-before-input -m state --state RELATED,ESTABLISHED -j ACCEPT
# drop INVALID packets
# uncomment to log INVALID packets
#-A ufw6-before-input -m state --state INVALID -j LOG --log-prefix "[UFW BLOCK INVALID]: "
-A ufw6-before-input -m state --state INVALID -j DROP
# connection tracking for outbound
-A ufw6-before-output -p tcp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
-A ufw6-before-output -p udp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT
# ok icmp codes
-A ufw6-before-input -p icmpv6 --icmpv6-type destination-unreachable -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type time-exceeded -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type parameter-problem -j ACCEPT
-A ufw6-before-input -p icmpv6 --icmpv6-type echo-request -j ACCEPT
# allow dhcp client to work
-A ufw6-before-input -p udp --sport 67 --dport 68 -j ACCEPT
# allow MULTICAST
-A ufw6-before-input -s ff00::/8 -j ACCEPT
-A ufw6-before-input -d ff00::/8 -j ACCEPT
# don't delete the 'COMMIT' line or these rules won't be processed
COMMIT